package com.ct.gd.passport.common.constants;

import android.content.Context;
import android.os.Environment;

public class Config {
	public static void init(String cachePath, Context context) {
		CACHE_PATH = cachePath;
		if (Environment.MEDIA_MOUNTED.equals(Environment.getExternalStorageState()))
			;
	}

	public static String CACHE_PATH;

	public static int DEFAULT_PAGE_SIZE = 99;
	public static int DEFAULT_PAGE_INDEX = 0;

	public static String BAIDU_MAP_KEY = "402E6ECBEB3C8355BD05E514E10C0491EBDDB6F4";

	public static String YY_URL = "http://gdcrj.com/message/transact.do?method=viewds&city=440600000000";

	public static Area currentArea = Area.HKG;
	public static String SEND_ADDRESS = "18925122633";
	public static String SEND_AGREE_CONTENT = "本人接受天翼港澳通的用户服务协议，并同意开通服务";
	public static String SEND_COMMIT_ERROR_CONTENT = "用户提交签注申请到公安厅失败";

	public static boolean ON_LINE = true;

	public static boolean PASSPORT_TEST = false;

	public static boolean PASSPORT_RECORD_ONLINE = false;
	
	public static final String WEBSERVICE_NAME_SPACE = "http://119.145.141.231/soap/bookCrj/";
	public static final String WEBSERVICE_WSDL = "http://119.145.141.231:20105/webservice/fshb_crj.php";

	public static enum Area {
		HKG("HKG", "香港", new double[] { 22.396428, 114.10949700000003 }, UmengVar.TRAVEL_DISCOUNT_HKG), 
		MAC("MAC", "澳门", new double[] { 22.198745, 113.54387300000008 }, UmengVar.TRAVEL_DISCOUNT_MAC),
		GZ("GZ", "广州", new double[] { 23.1318368234, 113.2591134973 }, UmengVar.TRAVEL_DISCOUNT_GZ), 
		FS("FS", "佛山", new double[] { 23.0240907030, 113.1159282004 }, UmengVar.TRAVEL_DISCOUNT_FS);

		public String code;
		public String name;
		public double[] jw;
		public String eventId;

		Area(String code, String name, double[] jw, String eventId) {
			this.code = code;
			this.name = name;
			this.jw = jw;
			this.eventId = eventId;
		}

		public static final Area getAreaByCode(String code) {
			if (HKG.code.equals(code)) {
				return HKG;
			} else if (MAC.code.equals(code)) {
				return MAC;
			} else if (GZ.code.equals(code)) {
				return GZ;
			} else if (FS.code.equals(code)) {
				return FS;
			}
			return null;
		}

	}
}
